package com.example.coffeesystem.controller;

import com.example.coffeesystem.utils.Result;
import com.example.coffeesystem.service.StaffServicce;
import com.example.coffeesystem.vo.LoginVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

//登录以及退出相关接口，获取当前用户登录的基本信息
@RestController
public class LoginController {
    @Autowired
    private StaffServicce staffServicce;

    @PostMapping("/login")
    public Result login(@RequestBody LoginVo loginVo){
        return staffServicce.login(loginVo);
    }

}
